package org.icress.fusion.admin

import org.icress.fusion.shiro.User

class ShareRole {

	User user
	Group group
	String domain
	Boolean read
	Boolean edit
	Boolean delete
	
    static constraints = {
		user (nullable:false)
		group(nullable:false)
		domain(nullable:false)
		read(nullable:true)
		edit(nullable:true)
		delete(nullable:true)
    }

    String toString() {
        return "$user.username - $group.name - $domain"
    }

	static mapping = {
		table 'ADMIN_SHAREROLE'
        read column : '_read'
        edit column : '_edit'
        delete column : '_delete'
        
	}
}
